Optics used to image a faraway scene can be thought of as performing mathematical operations transforming light intensities from different incident angles to locations on a two-dimensional image sensor. In the case of focusing optics, this transformation is the identity function: each angle is mapped to a distinct corresponding point on the sensor. When focusing optics are impractical due to size or material constraints, the right diffractive optic can perform an operation on light from incident angles other than the identity function that is nonetheless transformable to an approximation to the identity function mathematically. In such cases the sensed data may bear little or no resemblance to the captured scene; however, an image (or, more generally, a desired optical discrimination) can still be computed from the sensor outputs.